package com.codesuc.aichat.common.base;

/**
 * @Author: ZhangGongMing
 * @CreateTime: 2025-08-07
 * @Description: 公共分页参数对象
 * @Version: 1.0
 */
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;

@Data
@Schema(title = "公共分页参数对象")
public class BasePageRequest implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 当前页码
     */
    @Schema(name = "当前页码", defaultValue = "1")
    private Integer pageNo = 1;

    /**
     * 每页条数
     */
    @Schema(name = "每页条数", defaultValue = "10")
    private Integer pageSize = 10;

    /**
     * 排序字段
     */
    @Schema(name = "排序字段")
    private String orderBy;

    /**
     * 排序方式 asc/desc
     */
    @Schema(name = "排序方式 true 表示升序 ASC，false 表示降序 DESC")
    private Boolean orderType = false;

}
